import React from "react";
import style from './sourceTop.module.scss'
import '../../../assest/iconfont/icon.css'
class SourceTop extends React.PureComponent{
    constructor(props) {
        super(props);
        this.state = {
        }
    }
    render() {
        return (
            <div className={style.source}>
                <div className={style.top}>
                    <span className='iconfont iconzuojiantou' onClick={()=>{this.back()}}></span>
                    <h3>{this.props.title}</h3>
                    <i className={'iconfont iconsousuo '+style.search}></i>
                    <i className='iconfont iconliaotian'></i>
                </div>
                <div className={style.wrapper}>
                        <div className={style.banner}>
                            {
                                this.props.item.map(value => {
                                    return (
                                        <div className={style.item} key={value}>
                                            <img src={value} alt=""/>
                                        </div>
                                    )
                                })
                            }
                        </div>
                </div>
            </div>
        );
    }
    back(){
        window.history.back()
    }
}
export default SourceTop